package com.example.tabbar

import ZtlApi.ZtlManager
import android.content.Intent
import android.os.Bundle
import androidx.activity.enableEdgeToEdge
import androidx.appcompat.app.AppCompatActivity
import androidx.core.view.ViewCompat
import androidx.core.view.WindowInsetsCompat
import com.example.tabbar.activity.TabarActivity
import com.junray.usermangement.room.repository.UserRepository

class MainActivity : AppCompatActivity() {
    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        enableEdgeToEdge()
        setContentView(R.layout.activity_main)
        ViewCompat.setOnApplyWindowInsetsListener(findViewById(R.id.main)) { v, insets ->
            val systemBars = insets.getInsets(WindowInsetsCompat.Type.systemBars())
            v.setPadding(systemBars.left, systemBars.top, systemBars.right, systemBars.bottom)
            insets
        }
        UserRepository.getInstance(this).init("20070707", "1.2.0")
        //初始话屏幕sdk
//        SdkApi.newInstance(this)

//        ZtlManager.GetInstance().setContext(this)
        val intent = Intent(this, TabarActivity::class.java)
        startActivity(intent)
        finish()
    }
}